<template>
    <!-- <h2>订单列表</h2> -->
    <div class="box">
        <!-- 表头 -->
        <VsiTitle></VsiTitle>
		<el-card class="box-card">
			<!-- 表格 -->
			<div style="margin-top: 15px;" class="search">
				<el-input placeholder="请输入内容" class="input-with-select">
					<el-button slot="append" icon="el-icon-search"></el-button>
				</el-input>
			</div>
			<!-- 表单 -->
			<TableDing :list="list" :addFlag="addFlag"></TableDing>
    	</el-card>
    </div>
</template>

<script>
import VsiTitle from './vsiTitle.vue';
import TableDing from './TableDing.vue';
export default {
    name: "VisitorView",
    components: { VsiTitle, TableDing },
	data(){
		return {
			params:{
				pagenum:1,
				pagesize:10
			},
			addFlag:false,
			list:[]
		}
	},
	methods:{
		init(){
			//数据初始化
			this.getTableDate()
		},
		async getTableDate(){
			//发送Ajax请求
            let res = await this.$http.DingList(this.params)
			this.list = res.data.data.goods;
			// console.log(res)
		}
	},
	created(){
		this.$nextTick(() => {
			this.init();
		})
	},
}
</script>

<style lang="scss" scoped>
.search{
    display: flex;
    margin-bottom:20px; 
}
.el-input{
    width: 600px
}
.box-card{
	margin-top: 10px;
	margin-left: 20px;
}

</style>